/***************************************************************
 * Name:      Projet_wx2App.cpp
 * Purpose:   Code for Application Class
 * Author:     ()
 * Created:   2009-05-20
 * Copyright:  ()
 * License:
 **************************************************************/

#ifdef WX_PRECOMP
#include "wx_pch.h"
#endif

#ifdef __BORLANDC__
#pragma hdrstop
#endif //__BORLANDC__

#include "Projet_wx2App.h"
//#include "Menu.h"
//#include "AddEtu.h"

#include "Fenetres.h"

IMPLEMENT_APP(Projet_wx2App);

vector<Student> BD;
bool Projet_wx2App::OnInit()
{

   Men = new Menu(NULL);
   Add1 = new AddEtu(NULL);
    Modif= new ModifEtu(NULL);
    Men->Show(true);


    ////////////////////////////////PROGRAMME DE TEST///////////////////


    BD.push_back (Student("dupond","jean", "010203040506", "mon adresse", "GI"));
    BD[0].AddSemester();

    BD[0].AddSemester();
    BD[0].AddSemester();
    BD[0].RmSemester();

    BD[0].AddUv("Sy02");

    BD[0].AddUv("Sy01",1);

    BD[0].SetUv("Sy01","F",1);

    BD[0].AddUv("Sy03");

    BD[0].RmvUv("Sy03");

    BD[0].Affiche(cout);


    BD.push_back (Student("dupont","jeanne", "010203040506", "mon adresse", "GI"));
    BD[1].AddSemester();

    BD[1].AddUv("NF16");

    BD[1].AddUv("Sy01",1);

    BD[1].SetUv("NF16","F");

    BD[1].Affiche(cout);

    Semestre* s3000=BD[1].SelectSemestre();
    s3000->affiche();

    //BD.erase(--BD.end());

////////////////////////////////////// FIN DU TEST //////////////////////////////////////////

    return true;
}



